package com.cheer.dto;

import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @author cheer
 */
@Data
public class UserUpdateDTO {

    @NotBlank(message = "姓名不能为空")
    @Length(min = 1, max = 64, message = "姓名长度不能超过64字")
    private String username;

    @NotNull(message = "所属单位不能为空")
    private Integer organization;

    @NotNull(message = "所属单位不能为空")
    private Integer office;

    @NotBlank(message = "联系方式不能为空")
    @Length(min = 11, max = 11, message = "联系方式长度必须为11位")
    private String phone;

    private String province;

    private String city;

    private String region;

    @Length(max = 255, message = "详细地址长度不能超过255个字符")
    private String address;
}
